package org.example;


/**
 * ClassName: WuDa
 * Package: org.example
 * Description: 目标类：Target.class
 *              JDK动态代理的前提是：目标类必须要有父接口
 * @Author wanghao
 * @Create 2024-07-08 8:44
 * @Version 1.0
 */
public class WuDa implements ISale {
    // 目标方法
    @Override
    public void saleShaoBing() {
        System.out.println("五道口烤饼店卖烤饼");
    }

    @Override
    public Integer saleJianBing() {
        System.out.println("五道口烤饼店卖煎饼");
        return 99;
    }

    @Override
    public void saleYueBing() {
        System.out.println("五道口烤饼店卖月饼");
        throw new RuntimeException("有虫子");
    }

    @Override
    public void saleJuice() {

        System.out.println("五道口烤饼店卖果汁");
    }
}
